package com.sdp.th.controller;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import com.sdp.core.bizc.vo.Result;
import com.sdp.th.db.th_eq_alarm_log.service.IThEqAlarmLogService;

@RestController
@RequestMapping("/AppController")
public class AppController {

	@Autowired
	private IThEqAlarmLogService iThEqAlarmLogService;
	
	/**
	 * 查询最新的温湿度报警
	 * @return
	 */
	@PostMapping(value = "/queryTopTHAlarmLog")
	public Result<?> queryTopTHAlarmLog(){
		return Result.ok(iThEqAlarmLogService.queryTop5AlarmLog());
	}
	
	
}
